 #include <sys/types.h>
 #include <sys/stat.h>
 #include <fcntl.h>
 #include <stdio.h>
 #include <unistd.h>
 int main()
 {
	int fd = open("./abc.c",O_RDWR);
	if(fd==-1)
	{
	printf("open filed\n");
	return -1;
	}
	printf("open succeed\n");
	char buf[30]="abcdefghigklmnopqrstuvwxyz";
	int ret=write(fd,buf,26);
	if(ret==-1)
	{
		printf("write faild\n");
		return -1;
	}
	printf("write succeed\n");
	
	close(fd);
	return 0;
	
 }
